package org.auf.controllers;

import java.io.IOException;

import org.auf.core.Controller;
import org.auf.model.dao.ITestDAO;
import org.auf.model.jdbc.TestDAOJDBC;
import org.auf.to.Test;

public class GenerateTestController extends Controller {

	@Override
	public void show() {
		// comprobar si es geek
		Test exam = new Test();
		ITestDAO testdao = new TestDAOJDBC();
		exam = testdao.selectRamdomTest();
		String idTest = exam.getId();
		try {
			response.sendRedirect("?action=showtest&=id" + idTest);
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
}
